﻿using MvcWechat.Common;
using System.Web.Mvc;

namespace MvcWechat.Controllers
{
    public class WapController : Controller
    {
        //
        // GET: /Wap/

        //
        private ActionResult CheckView()
        {
            { 
                string key = CommonPage.getKey();
                //供应商的KEY 包含下划线就标识二级 一级的KEY 不能有下划线
                if (key.Contains("_"))
                    ViewBag.IsHideSupplier= "2";
                else
                    ViewBag.IsHideSupplier = "1";
            }
            string viewName = RouteData.Values["action"].ToString();

            if (HttpContext.Session["CustomerID"] != null)
            {
                ViewBag.CustomerID = HttpContext.Session["CustomerID"];
            }
            else
            {
                ViewBag.CustomerID = "";
            }
            return View(viewName);

        }
        // 产品页面加搜索
        public ActionResult WhiteDias() { return CheckView(); }
        public ActionResult DiasFilter() { return CheckView(); }

        public ActionResult WhiteParcels() { return CheckView(); }
        public ActionResult ParcelFilter() { return CheckView(); }

        public ActionResult Ring() { return CheckView(); }
        public ActionResult RingFilter() { return CheckView(); }

        public ActionResult Gem() { return CheckView(); }
        public ActionResult GemFilter() { return CheckView(); }

        public ActionResult Emerald() { return CheckView(); }
        public ActionResult EmeraldFilter() { return CheckView(); }

        public ActionResult Gold() { return CheckView(); }
        public ActionResult GoldFilter() { return CheckView(); }


        //产品详细
        public ActionResult ProductDetails() { return CheckView(); }


        ///购物车
        public ActionResult Cart() { return CheckView(); }


        //下单
        public ActionResult OrderConfirm() { return CheckView(); }

        //订单
        public ActionResult Order() { return CheckView(); }

        //关于我

        public ActionResult Info() { return CheckView(); }

        public ActionResult Forget() { return CheckView(); }
        public ActionResult Login() { ManagerSession.RemoveSession("CustomerID"); return CheckView(); }
        public ActionResult Register() { return CheckView(); }

        public ActionResult AddressChoose() { return CheckView(); }
        public ActionResult AddressEdit() { return CheckView(); }
        public ActionResult AddressIncrease() { return CheckView(); }

    }
}
